﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage/MasterPage.master" AutoEventWireup="true" CodeFile="EmpLeaveList.aspx.cs" Inherits="Employees_EmpLeaveList" %>
<%@ Register Src="../Control/DepartmentDList.ascx" TagName="DepartmentDList" TagPrefix="uc1" %>
<%@ Register Src="../Control/SelUser.ascx" TagName="SelUser" TagPrefix="uc2" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Titile" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="Content" Runat="Server">
<InfoLight:WebDataSource ID="Master" runat="server" AutoApply="True" 
            WebDataSetID="WMaster" DataMember="EmpLeave" SelectCommand="">
        </InfoLight:WebDataSource>
<table cellpadding="0" cellspacing="5" class="TbSearch">
        <tr>
            <td style="width: 50px;">
                部门：
            </td>
            <td>
                <uc1:departmentdlist ID="Depart" runat="server" />
            </td>
            <td style="width: 50px;">
                员工：
            </td>
            <td>
                <uc2:seluser ID="SelUser" runat="server" />
            </td>
           
            <td style="text-align: right; margin-right: 10px;">
                <span class="roundbtn">
                    <asp:LinkButton ID="SearchButton" runat="server" Text="&nbsp;&nbsp;&nbsp;&nbsp;查&nbsp;&nbsp;询&nbsp;&nbsp;&nbsp;&nbsp;"
                        OnClick="Search_Click"></asp:LinkButton>
                </span>
            </td>
        </tr>
    </table>
     <div class="tabsI" >
    </div>
 
           <InfoLight:webgridview id="wgvMaster" runat="server"
            cellpadding="5" datasourceid="Master" forecolor="#333333" width="100%" 
        AbortIconUrl="../Image/UIPics/Abort.gif" AddIconUrl="../Image/UIPics/Add.gif" 
        ApplyIconUrl="../Image/UIPics/Apply.gif" 
        CancelIconUrl="../Image/UIPics/Cancel.gif" 
        MouseOverAbortIconUrl="../Image/UIPics/Abort2.gif" 
        MouseOverAddIconUrl="../Image/UIPics/Add2.gif" 
        MouseOverApplyIconUrl="../Image/UIPics/Apply2.gif" 
        MouseOverCancelIconUrl="../Image/UIPics/Cancel2.gif" 
        MouseOverOKIconUrl="../Image/UIPics/OK2.gif" 
        MouseOverQueryIconUrl="../Image/UIPics/Query2.gif" 
        OKIconUrl="../Image/UIPics/OK.gif" QueryIconUrl="../Image/UIPics/Query.gif" 
        HeaderStyleWrap="False" BackColor="White" BorderColor="White" 
        BorderStyle="Groove" BorderWidth="2px" 
        onrowdatabound="wgvMaster_RowDataBound">
            <PagerSettings Mode="NumericFirstLast" />
<FooterStyle BackColor="#507CD1" ForeColor="White" Font-Bold="True"></FooterStyle>
            <navcontrols>
<InfoLight:ControlItem ControlVisible="False" Size="25" 
                    MouseOverImageUrl="../image/uipics/add2.gif" ControlText="add" 
                    ControlName="Add" ControlType="Image" ImageUrl="../image/uipics/add.gif"></InfoLight:ControlItem>
<InfoLight:ControlItem ControlVisible="False" Size="25" 
                    MouseOverImageUrl="../image/uipics/ok2.gif" ControlText="Insert" 
                    ControlName="OK" ControlType="Image" ImageUrl="../image/uipics/ok.gif"></InfoLight:ControlItem>
<InfoLight:ControlItem ControlVisible="False" Size="25" 
                    MouseOverImageUrl="../image/uipics/cancel2.gif" ControlText="cancel" 
                    ControlName="Cancel" ControlType="Image" ImageUrl="../image/uipics/cancel.gif"></InfoLight:ControlItem>
</navcontrols>
            <Columns>
                <asp:TemplateField HeaderText="查看详细">                    
                     <HeaderStyle Wrap="False" />
                    <itemstyle horizontalalign="Center" />
                    <itemtemplate>
                    <asp:ImageButton ID="imb" runat="server" ImageUrl="../Image/UIPics/Select.gif" 
                            CommandName="show" ></asp:ImageButton>
                   </itemtemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="EmpLeaveId" HeaderText="编号" 
                    SortExpression="EmpLeaveId" />
                <asp:TemplateField HeaderText="员工" SortExpression="EmployeeId">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("EmployeeId") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <InfoLight:WebDropDownList ID="WebDropDownList1" runat="server" 
                            AutoInsertEmptyData="False" DriverObject="" Filter="" FilterObject="" 
                            onlyshowselecttext="True" SelectedValue='<%# Bind("EmployeeId") %>' 
                            DataSourceID="wdsEmpName" DataTextField="EmpName" DataValueField="EmployeeId">
                        </InfoLight:WebDropDownList>
                    </ItemTemplate>
                </asp:TemplateField>
                    <asp:BoundField DataField="DepartmentName" HeaderText="所属部门" 
                    SortExpression="DepartmentName" />
                <asp:TemplateField HeaderText="离职类型" SortExpression="LeaveType">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("LeaveType") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <InfoLight:WebDropDownList ID="WebDropDownList2" runat="server" 
                            AutoInsertEmptyData="False" DataSourceID="wdsLeaveType" 
                            DataTextField="ValueName" DataValueField="ValueId" DriverObject="" Filter="" 
                            FilterObject="" onlyshowselecttext="True" 
                            SelectedValue='<%# Bind("LeaveType") %>'>
                        </InfoLight:WebDropDownList>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="离职时间" SortExpression="LeaveTime">
                    <EditItemTemplate>
                        <InfoLight:WebDateTimePicker ID="wdtEmpLeaveLeaveTimeE" runat="server" 
                            DateFormat="None" DateTimeType="DateTime" Localize="False" MaxYear="2050" 
                            MinYear="1950" Text='<%# Bind("LeaveTime") %>' ToolTip="LeaveTime" 
                            UseButtonImage="True" Width="100px"></InfoLight:WebDateTimePicker>
                    </EditItemTemplate>
                    <FooterTemplate>
                        <InfoLight:WebDateTimePicker ID="wdtEmpLeaveLeaveTimeF" runat="server" 
                            DateFormat="None" DateTimeType="DateTime" Localize="False" MaxYear="2050" 
                            MinYear="1950" ToolTip="LeaveTime" UseButtonImage="True" Width="100px"></InfoLight:WebDateTimePicker>
                    </FooterTemplate>
                    <ItemTemplate>
                        <asp:Label ID="lEmpLeaveLeaveTime" runat="server" 
                            Text='<%# Bind("LeaveTime", "{0:d}") %>' ToolTip="LeaveTime"></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="操作人" SortExpression="EditEmpId">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox3" runat="server" Text='<%# Bind("EditEmpId") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <InfoLight:WebDropDownList ID="WebDropDownList3" runat="server" 
                            AutoInsertEmptyData="False" DataSourceID="wdsEmpName" DataTextField="EmpName" 
                            DataValueField="EmployeeId" DriverObject="" Filter="" FilterObject="" 
                            onlyshowselecttext="True" SelectedValue='<%# Bind("EditEmpId") %>'>
                        </InfoLight:WebDropDownList>
                    </ItemTemplate>
                </asp:TemplateField>
</Columns>

<RowStyle BackColor="#EFF3FB" HorizontalAlign="Center"></RowStyle>

<EditRowStyle BackColor="#2461BF"></EditRowStyle>

<SelectedRowStyle BackColor="#D1DDF1" ForeColor="#333333" Font-Bold="True"></SelectedRowStyle>

<PagerStyle BackColor="LightBlue" ForeColor="White" HorizontalAlign="Center"></PagerStyle>

<HeaderStyle BackColor="DeepSkyBlue" ForeColor="White" Font-Bold="True"></HeaderStyle>

<AlternatingRowStyle BackColor="White" BorderColor="White"></AlternatingRowStyle>
</InfoLight:webgridview><br /><br />
<div style="text-align:center">

 <span class="roundbtn" runat="server" id="RedBack">
                    <asp:LinkButton ID="LinkButton1" runat="server" Text="&nbsp;&nbsp;&nbsp;&nbsp;返&nbsp;&nbsp;回&nbsp;&nbsp;&nbsp;&nbsp;"
                         OnClientClick="location.href='EmployeesInOut.aspx';return false"></asp:LinkButton>
                </span>
</div>
 <infolight:webdatasource runat="server" id="wdsLeaveType" selectalias="Usasdb" selectcommand="select Employees_LinkValue.ValueId,Employees_LinkValue.ValueName,Employees_LinkValue.TypeId,Employees_LinkValue.ValueStatus from Employees_LinkValue
where TypeId='LeaveType'">
    </infolight:webdatasource>

    <infolight:webdatasource runat="server" id="wdsEmpName" selectalias="Usasdb" selectcommand="select EmployeeId,EmpName from Employees">
    </infolight:webdatasource>
</asp:Content>

